package svc

import (
	"github.com/zeromicro/go-zero/zrpc"
	"gozeroProject/api/internal/config"
	"gozeroProject/rpc/pb/user"
)

type ServiceContext struct {
	Config config.Config

	UserRpc user.UserClient
}

func NewServiceContext(c config.Config) *ServiceContext {
	return &ServiceContext{
		Config: c,

		UserRpc: user.NewUserClient(zrpc.MustNewClient(c.UserRpc).Conn()),
	}
}
